import request from '@/utils/request'
import {encodeParams} from '@/utils'

/*// 列表
export function getList(data) {
  return request({
    url: `/api/contract?${encodeParams(data)}`,
    method: 'GET',
  })
}*/

// /

//添加
export function create(data) {
  return request({
    url: '/api/contract',
    method: 'POST',
    data
  })
}

//获取登录状态下的用户信息
export function getUserList(data) {
  return request({
    url: `/api/user/tenant/login`,
    method: 'GET',
  })
}


//获取登录状态下的用户信息
export function contractFee(data) {
  return request({
    url: `/api/contract-fee`,
    method: 'POST',
    data
  })
}

//根据id查询
export function getById(id) {
  return request({
    url: `/api/contract/${id}`,
    method: 'GET',
  })
}

//更新contract
export function update(id,data) {
  return request({
    url: `/api/contract/${id}`,
    method: 'PUT',
    data
  })
}

//更新contract
export function deleteIt(id) {
  return request({
    url: `/api/contract/${id}`,
    method: 'DELETE',
  })
}

